<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ include file="../common.inc" %>    
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
<link href="./css/style1.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="./js/form.js"></script>
<script type="text/javascript" language="javascript">
<!--
	function back(){
		window.location.href = "./role.do";
		window.location.target = "main";
	}
-->
</script>
</head>
<body>
	<table class="table_frame">
		<tr>
			<td>
				<table class="table_title1">
					<tr>
						<td class="title_lab">
							<fmt:message key='role.title.assignUser'/>
						</td>
					</tr>
					<tr>
						<td valign="bottom" align="right" class="a_tools">
							<a href="javascript:back();" title="<fmt:message key='common.button.back'/>" hidefocus="true"><fmt:message key='common.button.back'/></a>&nbsp;&nbsp;
						</td>
					</tr>
					<tr><td height="2"></td></tr>
				</table>
			</td>
		</tr>
		<tr>
			<td>
				<table class="table_title2">
					<tr>
						<td class="title_lab">
							<fmt:message key='role.title.assignUser'/>
						</td>
					</tr>
					<tr>
						<td>
							<table class="table">
								<tr>
									<td valign="top">
										<table class="table_style">
											<tr>
												<td class="title" width="8"></td>
												<td class="title" width="12%"><fmt:message key='user.lable.userCode'/></td>
												<td class="title" width="12%"><fmt:message key='user.lable.userName'/></td>
												<td class="title" width="12%"><fmt:message key='user.lable.deptName'/></td>
											</tr>
											<c:forEach var="user" items="${users}">
											<tr onmouseover="onmousemoveChange(this,'img${user.id}')" onmouseout="onmouseoutChange(this,'img${user.id}')">
												<td height="16" width="8" align="right"><img id="img${user.id}" src="./images/table_sign2.bmp"></td>
												<td>${user.userCode}</td>
												<td>${user.userName}</td>
												<td>${user.deptName}</td>
											</tr>
											</c:forEach>
										</table>
									</td>
								</tr>
								<tr>
									<td>
										<!-- page -->
										<table class="table_page">
											<tr>
												<td class="a_tools">
													${totalRows}&nbsp;<fmt:message key='common.page.totalRow'/>&nbsp;&nbsp;
													<fmt:message key='common.page.totalPage'/>&nbsp;${totalPages}&nbsp;<fmt:message key='common.page'/>&nbsp;&nbsp;
													<fmt:message key='common.page.current'/>&nbsp;${currentPage}&nbsp;<fmt:message key='common.page'/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
													<a href="./role.do?action=viewRoleUsers&flag=1&roleId=${roleId}" target="main" hidefocus="true"><fmt:message key='common.page.first'/></a>&nbsp;&nbsp;
													<a href="./role.do?action=viewRoleUsers&flag=2&roleId=${roleId}" target="main" hidefocus="true"><fmt:message key='common.page.previous'/></a>&nbsp;&nbsp;
													<a href="./role.do?action=viewRoleUsers&flag=3&roleId=${roleId}" target="main" hidefocus="true"><fmt:message key='common.page.next'/></a>&nbsp;&nbsp;
													<a href="./role.do?action=viewRoleUsers&flag=4&roleId=${roleId}" target="main" hidefocus="true"><fmt:message key='common.page.last'/></a>
												</td>
											</tr>
										</table>
									</td>
								</tr>
							</table>
						</td>
					</tr>
				</table>
			</td>
		</tr>
	</table>
</body>
</html>